package com.caiyouxi.util;

/*import com.u8.server.data.UMsdkOrder;
import com.u8.server.data.UOrder;
import com.u8.server.data.UUser;
import com.u8.server.log.Log;*/

import java.util.UUID;

public class UGenerator {

    /***
     * 生成appkey
     * @param app_id
     * @return
     */
    public static String generate_app_key(int app_id){

        String txt = app_id + "" + System.currentTimeMillis();
        return EncryptUtils.md5(txt);
    }

    /***
     * 生成appsecret
     *
     * @return
     */
    public static String generate_app_secret(){
        UUID uuid = UUID.randomUUID();
        return EncryptUtils.md5(uuid.toString());
    }

    public static void main(String[] args){
        System.out.println("Key:    "+UGenerator.generate_app_key(2003));
        System.out.println("Secret   :"+UGenerator.generate_app_secret());
    }

}
